Skip to content

Conversation

@npmccallum
Copy link
Collaborator

No description provided.

Copilot AI review requested due to automatic review settings October 14, 2025 19:09
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for setting milestones when creating GitHub issues. The implementation introduces a new Milestone enum that can handle both milestone IDs and titles, and adds milestone functionality to the issue creation workflow.

Key changes:

  • Added a flexible Milestone enum supporting both ID and title-based milestone references
  • Extended the Report struct to include an optional milestone field

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@npmccallum
Copy link
Collaborator Author

@amd-aliem https://docs.github.com/en/rest/issues/issues?apiVersion=2022-11-28#create-an-issue

That's the API we're triggering on the GitHub side. You can see we're only adding the milestone field to that JSON object. This can be either an int or string. If I understand it correctly, when it is an int it refers to the milestone number but when it is a string it refers to the milestone title. This is why we preserve the difference between the types. In other words beacon report --milestone 123 will use the milestone number but beacon report --milestone v3.0-0 will use the milestone title.

This allows us to hold state across GitHub requests without
exposing that state as a command line option.
Workloaads likely know only the name of the milestone. On the
other hand, the GitHub API knows only about the number of the
milestone. Therefore, we load all milestones during launch so
that we can automatically resolve the milestone number from the
name.
@DGonzalezVillal
Copy link

I approved I just want to understand that one point I had above

@amd-aliem
Copy link
Contributor

amd-aliem commented Oct 15, 2025

Tested w/ beacon passing --milestone "v3.0-0" - successfully opened an issue associated w/ that milestone in my fork: amd-aliem/sev-certify#17

Note that if a milestone is specified that is NOT found in the target repo, the issue is not created.

@npmccallum
Copy link
Collaborator Author

@DGonzalezVillal I think you have to approve again because I resolved your comment.

@DGonzalezVillal
Copy link

I approved, but I don't have write access

@npmccallum npmccallum disabled auto-merge October 15, 2025 21:03
@npmccallum npmccallum merged commit 6be4b1a into AMDEPYC:main Oct 15, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants